
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8"/>
    <title>IconFont</title>
    <link rel="stylesheet" href="demo.css">
    <script src="iconfont.js"></script>

    <style type="text/css">
        .icon {
          /* 通过设置 font-size 来改变图标大小 */
          width: 1em; height: 1em;
          /* 图标和文字相邻时，垂直对齐 */
          vertical-align: -0.15em;
          /* 通过设置 color 来改变 SVG 的颜色/fill */
          fill: currentColor;
          /* path 和 stroke 溢出 viewBox 部分在 IE 下会显示
             normalize.css 中也包含这行 */
          overflow: hidden;
        }

    </style>
</head>
<body>
    <div class="main markdown">
        <h1>IconFont 图标</h1>
        <ul class="icon_lists clear">
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-bijiben"></use>
                    </svg>
                    <div class="name">笔记本</div>
                    <div class="fontclass">#icon-bijiben</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xitongguanli"></use>
                    </svg>
                    <div class="name">系统管理</div>
                    <div class="fontclass">#icon-xitongguanli</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-chevron-down"></use>
                    </svg>
                    <div class="name">下</div>
                    <div class="fontclass">#icon-chevron-down</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-chevron-right"></use>
                    </svg>
                    <div class="name">右</div>
                    <div class="fontclass">#icon-chevron-right</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-chevron-left"></use>
                    </svg>
                    <div class="name">左</div>
                    <div class="fontclass">#icon-chevron-left</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-cogs3"></use>
                    </svg>
                    <div class="name">设置</div>
                    <div class="fontclass">#icon-cogs3</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-msnui-ban"></use>
                    </svg>
                    <div class="name">禁止</div>
                    <div class="fontclass">#icon-msnui-ban</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-diannao"></use>
                    </svg>
                    <div class="name">电脑</div>
                    <div class="fontclass">#icon-diannao</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-youxian"></use>
                    </svg>
                    <div class="name">有线</div>
                    <div class="fontclass">#icon-youxian</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-guanbi"></use>
                    </svg>
                    <div class="name">关闭</div>
                    <div class="fontclass">#icon-guanbi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-sousuo"></use>
                    </svg>
                    <div class="name">搜索</div>
                    <div class="fontclass">#icon-sousuo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-shouji"></use>
                    </svg>
                    <div class="name">手机</div>
                    <div class="fontclass">#icon-shouji</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-mima"></use>
                    </svg>
                    <div class="name">密码</div>
                    <div class="fontclass">#icon-mima</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-shanchu"></use>
                    </svg>
                    <div class="name">删除</div>
                    <div class="fontclass">#icon-shanchu</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-tianjia"></use>
                    </svg>
                    <div class="name">添加</div>
                    <div class="fontclass">#icon-tianjia</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-icontianjia01"></use>
                    </svg>
                    <div class="name">添加</div>
                    <div class="fontclass">#icon-icontianjia01</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-mianfeiyouxianshangwang"></use>
                    </svg>
                    <div class="name">免费有线上网</div>
                    <div class="fontclass">#icon-mianfeiyouxianshangwang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-tishi"></use>
                    </svg>
                    <div class="name">提示</div>
                    <div class="fontclass">#icon-tishi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-iconfontchajian"></use>
                    </svg>
                    <div class="name">基础插件</div>
                    <div class="fontclass">#icon-iconfontchajian</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-wifi"></use>
                    </svg>
                    <div class="name">wifi</div>
                    <div class="fontclass">#icon-wifi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-zhinengluyouqi"></use>
                    </svg>
                    <div class="name">智能路由器</div>
                    <div class="fontclass">#icon-zhinengluyouqi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-usertouxiang"></use>
                    </svg>
                    <div class="name">user头像</div>
                    <div class="fontclass">#icon-usertouxiang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-zuiyou"></use>
                    </svg>
                    <div class="name">最右</div>
                    <div class="fontclass">#icon-zuiyou</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-zuizuo"></use>
                    </svg>
                    <div class="name">最左</div>
                    <div class="fontclass">#icon-zuizuo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-heimingdan"></use>
                    </svg>
                    <div class="name">黑名单</div>
                    <div class="fontclass">#icon-heimingdan</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-sheweimoban"></use>
                    </svg>
                    <div class="name">设为模板</div>
                    <div class="fontclass">#icon-sheweimoban</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-count-copy"></use>
                    </svg>
                    <div class="name">统计</div>
                    <div class="fontclass">#icon-count-copy</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-fangzi"></use>
                    </svg>
                    <div class="name">房子</div>
                    <div class="fontclass">#icon-fangzi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-touxiang"></use>
                    </svg>
                    <div class="name">头像</div>
                    <div class="fontclass">#icon-touxiang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-bianji"></use>
                    </svg>
                    <div class="name">编辑</div>
                    <div class="fontclass">#icon-bianji</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xiangqing"></use>
                    </svg>
                    <div class="name">详情</div>
                    <div class="fontclass">#icon-xiangqing</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-wangluo"></use>
                    </svg>
                    <div class="name">网络</div>
                    <div class="fontclass">#icon-wangluo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-peizhiwukuang"></use>
                    </svg>
                    <div class="name">配置-无框</div>
                    <div class="fontclass">#icon-peizhiwukuang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-renqun"></use>
                    </svg>
                    <div class="name">人群</div>
                    <div class="fontclass">#icon-renqun</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-daochu"></use>
                    </svg>
                    <div class="name">导出</div>
                    <div class="fontclass">#icon-daochu</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xiangqing1"></use>
                    </svg>
                    <div class="name">详情</div>
                    <div class="fontclass">#icon-xiangqing1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-queren"></use>
                    </svg>
                    <div class="name">确认</div>
                    <div class="fontclass">#icon-queren</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-huojian"></use>
                    </svg>
                    <div class="name">火箭</div>
                    <div class="fontclass">#icon-huojian</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-suo"></use>
                    </svg>
                    <div class="name">锁</div>
                    <div class="fontclass">#icon-suo</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xin"></use>
                    </svg>
                    <div class="name">新</div>
                    <div class="fontclass">#icon-xin</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xiasanjiao-copy"></use>
                    </svg>
                    <div class="name">下三角</div>
                    <div class="fontclass">#icon-xiasanjiao-copy</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-suo1"></use>
                    </svg>
                    <div class="name">锁</div>
                    <div class="fontclass">#icon-suo1</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-fangke"></use>
                    </svg>
                    <div class="name">访客</div>
                    <div class="fontclass">#icon-fangke</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-yaochi"></use>
                    </svg>
                    <div class="name">钥匙</div>
                    <div class="fontclass">#icon-yaochi</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xiugaitouxiang"></use>
                    </svg>
                    <div class="name">头像</div>
                    <div class="fontclass">#icon-xiugaitouxiang</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-canyin2"></use>
                    </svg>
                    <div class="name">全部</div>
                    <div class="fontclass">#icon-canyin2</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-xia"></use>
                    </svg>
                    <div class="name">下</div>
                    <div class="fontclass">#icon-xia</div>
                </li>
            
                <li>
                    <svg class="icon" aria-hidden="true">
                        <use xlink:href="#icon-kaiguan-open"></use>
                    </svg>
                    <div class="name">开关</div>
                    <div class="fontclass">#icon-kaiguan-open</div>
                </li>
            
        </ul>


        <h2 id="symbol-">symbol引用</h2>
        <hr>

        <p>这是一种全新的使用方式，应该说这才是未来的主流，也是平台目前推荐的用法。相关介绍可以参考这篇<a href="">文章</a>
        这种用法其实是做了一个svg的集合，与另外两种相比具有如下特点：</p>
        <ul>
          <li>支持多色图标了，不再受单色限制。</li>
          <li>通过一些技巧，支持像字体那样，通过<code>font-size</code>,<code>color</code>来调整样式。</li>
          <li>兼容性较差，支持 ie9+,及现代浏览器。</li>
          <li>浏览器渲染svg的性能一般，还不如png。</li>
        </ul>
        <p>使用步骤如下：</p>
        <h3 id="-symbol-">第一步：引入项目下面生成的symbol代码：</h3>
        <pre><code class="lang-js hljs javascript"><span class="hljs-comment">&lt;script src="./iconfont.js"&gt;&lt;/script&gt;</span></code></pre>
        <h3 id="-css-">第二步：加入通用css代码（引入一次就行）：</h3>
        <pre><code class="lang-js hljs javascript">&lt;style type=<span class="hljs-string">"text/css"</span>&gt;
.icon {
   width: <span class="hljs-number">1</span>em; height: <span class="hljs-number">1</span>em;
   vertical-align: <span class="hljs-number">-0.15</span>em;
   fill: currentColor;
   overflow: hidden;
}
&lt;<span class="hljs-regexp">/style&gt;</span></code></pre>
        <h3 id="-">第三步：挑选相应图标并获取类名，应用于页面：</h3>
        <pre><code class="lang-js hljs javascript">&lt;svg <span class="hljs-class"><span class="hljs-keyword">class</span></span>=<span class="hljs-string">"icon"</span> aria-hidden=<span class="hljs-string">"true"</span>&gt;<span class="xml"><span class="hljs-tag">
  &lt;<span class="hljs-name">use</span> <span class="hljs-attr">xlink:href</span>=<span class="hljs-string">"#icon-xxx"</span>&gt;</span><span class="hljs-tag">&lt;/<span class="hljs-name">use</span>&gt;</span>
</span>&lt;<span class="hljs-regexp">/svg&gt;
        </span></code></pre>
    </div>
</body>
</html>
